import BaseComponent from "http://component.119safe.cn/component/base.js";

new class Nav extends BaseComponent
{
	/*
	 * web-logo		一般为网站图标
	 * web-name		一般为网站名称
	 * left-menu-container	菜单绑定元素(jquery选择)
	 */
	Properties = { "web-logo": "", "web-name": "", "left-menu-container": "" };

	InnerContainer = "ul.nav.ace-nav";

	render() { super.render(this.constructor.name); }

	Content = `
<div id="navbar" class="navbar navbar-default ace-save-state">
	<div class="navbar-container ace-save-state" id="navbar-container">
		<button type="button" class="navbar-toggle menu-toggler pull-left" id="menu-toggler" data-target="{left-menu-container}">
			<span class="icon-bar"></span>
			<span class="icon-bar"></span>
			<span class="icon-bar"></span>
		</button>

		<div class="navbar-header pull-left">
			<a href="http://ace.jeka.by/index.html" class="navbar-brand">
				<small>
					<i class="fa {web-logo}"></i>
					{web-name}
				</small>
			</a>
		</div>

		<div class="navbar-buttons navbar-header pull-right" role="navigation">
			<ul class="nav ace-nav"></ul>
		</div>
	</div><!-- /.navbar-container -->
</div>`;
}().render();
